<template>
  <div>
    <h2>秒杀</h2>
    <ul>
      <li v-for="miaoshaData in miaoshaDatas.time_list" :key="miaoshaData.id">
        <h2>{{ miaoshaData.title }}</h2>
      </li>
    </ul>
  </div>
</template>

<script>
import axios from "axios";
export default {
  methods: {
    getMiaoShaListDatas() {
      axios.get("api/visual/visual_seckill?id=28").then((res) => {
        console.log(res.data.data);
      });
    },
  },
  computed: {
    miaoshaDatas() {
      return this.$store.state.seckillListDatas;
    },
  },
  mounted() {
    this.$store.dispatch("actChangeSeckillListDatas", {
      id: 28,
    });
    this.getMiaoShaListDatas();
  },
};
</script>